package com.woniuxy;

import com.woniuxy.proxy.JdkProxyFactory;
import com.woniuxy.service.UserService;
import com.woniuxy.service.impl.UserServiceImpl;

/**
 * @author: ideaAdmin
 * Date: 2022/1/20:11:50
 * Description:
 */

public class test {
    public static void main(String[] args) {

        UserService userService = null;

       // userService = JdkProxyFactory.getObjectProxy(UserService.class);

        //userService.findAll();
       // userService.update();

        System.out.println("cglib动态代理-------");
        userService = JdkProxyFactory.getEnhancerProxy(UserServiceImpl.class);
        userService.findAll();
        userService.update();
    }



}
